import request from '@/utils/request'
export default{
    // 保存信息
    save(form){
        return request({
            url: '/project_source/proInfo/proRange/save',
            method: 'post',
            data: form
        })
    },
    // 获取信息
    openInfo(id){
        return request({
            url: '/project_source/proInfo/proRange/'+id,
            method: 'post'
        })
    },
    // 修改信息
    updateInfo(data){
        return request({
            url: '/project_source/proInfo/proRange/updata',
            method: 'post',
            params: data
        })
    },
    // 删除子地块信息
    deletesonInformation(id){
        return request({
            url: '/project_source/proInfo/proRange/childDelete/'+id,
            method: 'post',
        })
    },
    // 删除地块信息
    delete(id){
        return request({
            url: '/project_source/proInfo/proRange/delete/'+id,
            method: 'post',
        })
    },
    // 分页查询
    page(page,limit,proId,type){
        return request({
            url: '/project_source/proInfo/proRange/page/'+page+'/'+limit + '/' +proId +'/'+type,
            method: 'post',
        })
    },
    // 导入坐标
    input(formdata){
        return request({
            url: '/project_source/proInfo/proRange/input',
            method: 'post',
            data:formdata
        })
    },
    // 导出坐标toexcel
    toexcel(data){
        console.log(data);
        return request({
            url: '/project_source/proInfo/proRange/exportFile',
            method: 'post',
            params:data
        })
    },
    updateArea(area,id){
        return request({
            url: '/project_source/proInfo/proRange/updateProToRange/'+id,
            method: 'post',
            params:area
        })
    }
}